﻿// <copyright file="IService1.cs" company="company"> 
// (C) 2010 . All rights reserved
// </copyright>
// <author>Lukasz Bartczak</author>

namespace WcfService1
{
    using System;
    using System.Collections.Generic;
    using System.ServiceModel;

    /// <summary>
    /// Service interface
    /// </summary>
    [ServiceContract]
    public interface IServices
    {
        /// <summary>
        /// Contract od the Gets the child and opiekun by firstname and lastname method.
        /// </summary>
        /// <param name="firstname">The firstname.</param>
        /// <param name="lastname">The lastname.</param>
        /// <returns>
        /// List of generic collection of dziecko and opiekun
        /// </returns>
        [OperationContract]
        CustomCollection<DzieckoAndOpiekun> GetChildAndOpiekunByFirstnameLastname(string firstname, string lastname);

        /// <summary>
        /// Gets the child and opiekun from group.
        /// </summary>
        /// <param name="group">The group.</param>
        /// <returns>Collection of childerens and parents</returns>
        [OperationContract]
        CustomCollection<DzieckoAndOpiekun> GetChildAndOpiekunByGroup(int group);

        /// <summary>
        /// Gets the peyments by child and opiekun.
        /// </summary>
        /// <param name="dzieFirstname">The dziecko firstname.</param>
        /// <param name="dzieLastname">The dziecko lastname.</param>
        /// <param name="opieFirstname">The opiekun firstname.</param>
        /// <param name="opieLastname">The opiekun lastname.</param>
        /// <returns>Collection of Payment by dziecko.</returns>
        [OperationContract]
        CustomCollection<Payments> GetPeymentsByChildAndOpiekun(string dzieFirstname, string dzieLastname, string opieFirstname, string opieLastname);

        /// <summary>
        /// Gets the peyments by opiekun.
        /// </summary>
        /// <param name="opieFirstname">The opiekun firstname.</param>
        /// <param name="opieLastname">The opiekun lastname.</param>
        /// <returns>Collection of Payment by dziecko.</returns>
        [OperationContract]
        CustomCollection<Payments> GetPeymentsByOpiekun(string opieFirstname, string opieLastname);

        /// <summary>
        /// Adds the child and opiekun.
        /// </summary>
        /// <param name="dzieFirstname">The dziecko firstname.</param>
        /// <param name="dzieLastname">The dziecko lastname.</param>
        /// <param name="idGrupy">The id grupy.</param>
        /// <param name="opieFirstname">The opiekun firstname.</param>
        /// <param name="opieLastname">The opiekun lastname.</param>
        /// <param name="tel">The telephone number.</param>
        [OperationContract]
        void AddChildAndOpiekun(string dzieFirstname, string dzieLastname, int idGrupy, string opieFirstname, string opieLastname, int tel);

        /// <summary>
        /// Adds the kind of the payment.
        /// </summary>
        /// <param name="typ">The type of payment.</param>
        /// <param name="rodzajCzest">The rodzaj czest.</param>
        /// <param name="nazwa">The name of payment.</param>
        /// <param name="kwota">The kwota.</param>
        [OperationContract]
        void AddPaymentKind(string typ, string rodzajCzest, string nazwa, double kwota);

        /// <summary>
        /// Gets the groups.
        /// </summary>
        /// <returns>The groups.</returns>
        [OperationContract]
        IEnumerable<int> GetGroups();

        /// <summary>
        /// Gets the months.
        /// </summary>
        /// <returns>The months.</returns>
        [OperationContract]
        IEnumerable<string> GetMonths();

        /// <summary>
        /// Gets the kind of the class.
        /// </summary>
        /// <returns>Class kind.</returns>
        [OperationContract]
        IEnumerable<string> GetClassKind();

        /// <summary>
        /// Gets the type of the payment.
        /// </summary>
        /// <returns>Payment type.</returns>
        [OperationContract]
        IEnumerable<string> GetPaymentType();

        /// <summary>
        /// Gets the payment frequency.
        /// </summary>
        /// <returns>Payment frequency.</returns>
        [OperationContract]
        IEnumerable<string> GetPaymentFrequency();

        /// <summary>
        /// Adds the payment to child.
        /// </summary>
        /// <param name="dzieImie">The dziecko imie.</param>
        /// <param name="dzieNazwisko">The dziecko nazwisko.</param>
        /// <param name="opieImie">The opiekun imie.</param>
        /// <param name="opieNazwisko">The opiekun nazwisko.</param>
        /// <param name="rodzaj">The rodzaj pf payment.</param>
        /// <param name="miesiac">The miesiac.</param>
        /// <param name="terminPl">The termin platnosci.</param>
        [OperationContract]
        void AddPaymentToChild(string dzieImie, string dzieNazwisko, string opieImie, string opieNazwisko, string rodzaj, string miesiac, DateTime terminPl);
    }
}